# Maintainer: Antonio Rojas <arojas@archlinux.org>
# Maintainer: Felix Yan <felixonmars@archlinux.org>

pkgname=syntax-highlighting
pkgver=5.106.0
pkgrel=1
pkgdesc='Syntax highlighting engine for structured text and code'
arch=(x86_64)
url='https://community.kde.org/Frameworks'
license=(GPL2)
depends=(qt5-base)
makedepends=(extra-cmake-modules qt5-declarative qt5-xmlpatterns qt5-tools qt5-doc doxygen)
optdepends=('qt5-declarative: QML bindings')
groups=(kf5)
source=(https://download.kde.org/stable/frameworks/${pkgver%.*}/$pkgname-$pkgver.tar.xz{,.sig})
sha256sums=('cd80e3a3bb541f8337e9b29deeabd8545959a02ba1ed9384fb7e8dd7819b1c05'
            'SKIP')
validpgpkeys=(53E6B47B45CEA3E0D5B7457758D0EE648A48B3BB) # David Faure <faure@kde.org>

build() {
  cmake -B build -S $pkgname-$pkgver \
    -DBUILD_TESTING=OFF \
    -DQRC_SYNTAX=OFF \
    -DBUILD_QCH=ON
  cmake --build build
}

package() {
  DESTDIR="$pkgdir" cmake --install build
}
